package com.example.weibo.pojo.entity;

import java.util.Date;

/**
 * @Name: User
 * @Author: 西风残叶
 * @Company: 朝兮网络工作室
 * @Data: 2023/11/16 21:38
 */
public class User {
    private Integer id;
    private String username;
    private String password;
    private String nickname;
    private Date created; // 创建时间,需要导入java.util包
    /*
        添加一个字段
        use weibo;
        alter table user add created timestamp;
     */

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", username='" + username + '\'' +
                ", password='" + password + '\'' +
                ", nickname='" + nickname + '\'' +
                ", create=" + created +
                '}';
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public Date getCreated() {
        return created;
    }

    public void setCreated(Date created) {
        this.created = created;
    }
}
